<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>Document</title>
</head>
<body>
	<img src='./mn.png' style="position:relative;top:0px;left:0px;" />
</body>
<script type="text/javascript">
	var img = document.getElementsByTagName('img')[0];
	img.onclick = function(){
		alert('嫁给我');
	}

	img.onmouseover = function(ev){
		img.style.left = ev.pageX + 2 + "px";
		img.style.top = ev.pageY + 2 + 'px';
	}
</script>
</html>